#include <iostream>
#include <cstring>
#include <queue>
#include <vector>
#include <algorithm>
using namespace std;
#define maxn 500001
const int INF = 1 << 30;

int n, m, s, p;
vector<int> G[maxn];
vector<int> rG[maxn];
vector<int> seq;
bool used[maxn];
int sccid[maxn];
vector<int> rsccid[maxn];
int csccidnum[maxn];
int deg[maxn];
int sccnum;
int node_weight[maxn];
int goal[maxn];
int dis[maxn];
bool visited[maxn];
vector<int> G2[maxn];
int node_weight2[maxn];
int ans=0;

void add_edge(int from, int to) {
    G[from].push_back(to);
    rG[to].push_back(from);
}

void dfs(int u) {
    used[u] = true;
    for (int i = 0; i<G[u].size(); i++) {
        int v = G[u][i];
        if (!used[v]) dfs(v);
    }
    seq.push_back(u);
}

void rdfs(int u, int _sccid) {
    used[u] = true;
    sccid[u] = _sccid;
    rsccid[_sccid].push_back(u);
    csccidnum[_sccid]++;
    for (int i = 0; i<rG[u].size(); i++) {
        int v = rG[u][i];
        if (!used[v]) rdfs(v, _sccid);
    }
}

int scc() {
    memset(used, 0, sizeof(used));
    seq.clear();
    for (int u = 1; u <= n; u++) {
        if (!used[u]) dfs(u);
    }
    memset(used, 0, sizeof(used));
    int _sccid = 0;
    for (int i = seq.size() - 1; i >= 0; i--) {
        int v = seq[i];
        if (!used[v]) {
            rdfs(v, _sccid);
            _sccid++;
        }
    }
    return _sccid;
}


void rebuild_graph(int sccnum) {
    for (int csccid = 0; csccid < sccnum; csccid++) {
        int csccw = 0;
        for(auto u : rsccid[csccid]) {
            csccw += node_weight[u];
            for(auto v : G[u])
                if(sccid[u] != sccid[v])
                    G2[csccid].push_back(sccid[v]);
        }
        node_weight2[csccid] = csccw;
    }
}

void SPFA(int s) {
    for (int i = 0; i <= n; i++) dis[i] = INF;
    queue<int> que;
    dis[s] = node_weight2[s];
    visited[s] = true;
    que.push(s);
    int u;
    while (!que.empty()) {
        u = que.front(); que.pop();
        visited[u] = false;
        for (auto son : G2[u]) {
            int v = son;
            int w = node_weight2[son];
            if (dis[v] > dis[u] + w) {
                dis[v] = dis[u] + w;
                if (!visited[v]) {
                    que.push(v);
                    visited[v] = true;
                }
            }
        }
    }
}

int main()
{
    cin >> n >> m;
    for (int i = 0; i < m; i++) {
        int u, v;
        cin >> u >> v;
        add_edge(u, v);
    }
    for (int i = 1; i <= n; i++) {
        int w;
        cin >> w;
        node_weight[i] = -w;
    }
    cin >> s >> p;
    for (int i = 0; i < p; i++) {
        cin >> goal[i];
    }

    int sccnum = scc();
    rebuild_graph(sccnum);
    SPFA(sccid[s]);
    
    for(int i=0; i<p; i++){
        ans = max(ans, -dis[sccid[goal[i]]]);
    }
    cout << ans << endl;

    return 0;
}
